widget-factory: Expand the treeview example a bit
authorMatthias Clasen <mclasen@redhat.com>
Thu, 3 Jul 2014 03:55:20 +0000 (23:55 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Thu, 3 Jul 2014 03:55:20 +0000 (23:55 -0400)
Show resizable, sortable and ellipsizable columns.

demos/widget-factory/widget-factory.ui

index 9f2a097cd6ddb5b7c5ea86fc21de6a8bbd814db3..b0f19177b8798a458617013dd7020eba830c0313 100644 (file)
         <col id="2" translatable="yes">Otto</col>
         <col id="3" translatable="yes">chaotic</col>
       </row>
+      <row>
+        <col id="0">True</col>
+        <col id="1">weather-clear-night-symbolic</col>
+        <col id="2" translatable="yes">Orville</col>
+        <col id="3" translatable="yes">Redenbacher</col>
+      </row>
     </data>
   </object>
   <object class="GtkTextBuffer" id="textbuffer1">
@@ -1366,8 +1372,13 @@ Suspendisse feugiat quam quis dolor accumsan cursus. </property>
                                 <child>
                                   <object class="GtkTreeViewColumn" id="treeviewcolumn1">
                                     <property name="title" translatable="yes">Name</property>
+                                    <property name="resizable">True</property>
+                                    <property name="sort-indicator">True</property>
+                                    <property name="sort-column-id">2</property>
                                     <child>
-                                      <object class="GtkCellRendererText" id="cellrenderertext3"/>
+                                      <object class="GtkCellRendererText" id="cellrenderertext3">
+                                        <property name="ellipsize">end</property>
+                                      </object>
                                       <attributes>
                                         <attribute name="text">2</attribute>
                                       </attributes>
@@ -1377,8 +1388,13 @@ Suspendisse feugiat quam quis dolor accumsan cursus. </property>
                                 <child>
                                   <object class="GtkTreeViewColumn" id="treeviewcolumn2">
                                     <property name="title" translatable="yes">Nick</property>
+                                    <property name="resizable">True</property>
+                                    <property name="sort-indicator">True</property>
+                                    <property name="sort-column-id">3</property>
                                     <child>
-                                      <object class="GtkCellRendererText" id="cellrenderertext4"/>
+                                      <object class="GtkCellRendererText" id="cellrenderertext4">
+                                        <property name="ellipsize">end</property>
+                                      </object>
                                       <attributes>
                                         <attribute name="text">3</attribute>
                                       </attributes>